-- GENERATED SPELL FOR [Amanitar] --


function spell0_30258(pUnit, Event) --@Bash,n/a--
pUnit:FullCastSpellOnTarget(57094,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_30258', 610, 1)
end

function spell1_30258(pUnit, Event) --@Entangling Roots,n/a--
pUnit:FullCastSpellOnTarget(57095,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_30258', 10000, 1)
end

function spell2_30258(pUnit, Event) --@Mini,n/a--
pUnit:FullCastSpellOnTarget(57055,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_30258', 2500, 1)
end

function spell3_30258(pUnit, Event) --@Venom Bolt Volley,n/a--
pUnit:FullCastSpellOnTarget(57088,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_30258', 2000, 1)
end

function Sorts_30258(pUnit, Event)
local choix_sorts_30258 = math.random(0, 3)
if choix_sorts_30258 == 0 then
pUnit:RegisterEvent('spell0_30258', 1, 1)
end
if choix_sorts_30258 == 1 then
pUnit:RegisterEvent('spell1_30258', 1, 1)
end
if choix_sorts_30258 == 2 then
pUnit:RegisterEvent('spell2_30258', 1, 1)
end
if choix_sorts_30258 == 3 then
pUnit:RegisterEvent('spell3_30258', 1, 1)
end
end

function mob30258_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_30258', math.random(1500, 3000), 1)
end

function mob30258_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob30258_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob30258_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(30258, 1, 'mob30258_Action')
RegisterUnitEvent(30258, 2, 'mob30258_Leave')
RegisterUnitEvent(30258, 3, 'mob30258_Kill')
RegisterUnitEvent(30258, 4, 'mob30258_Die')
